{include file="headerPopup.tpl.html"}


<!--<div class="widthContent tableDiv radiusDiv shadowDiv darkBlueDiv2" style=" padding-top:4px;padding-bottom:4px;margin-bottom:20px;margin-top:10px;">	
	<div class="rowTableDiv ">
		<div class="cellTableDiv widthContent divFloat leftTopRadiusDiv rightTopRadiusDiv" style="border:none;"> 
			<table class="widthMax100 textColorWhite tableGridNew textAlignLeft fontStyleNew textColorGrey" style="margin: 2px;">
				<thead>
					<tr>
						<td >Benvenuto <b>{$usrNominativo}</b>, seleziona una campagna per iniziare.</td>
						<td class="menuText shadowTextGrey" >|</td>
						<td id="home" class="menuText shadowTextGrey" onClick="openMenu('endSession')">Logout</td>
					</tr>
					
						
				</thead>
			</table>
		</div>
	</div>
</div>-->


<div id="divContent" class="widthContent radiusDiv shadowDiv backWhite textAlignLeft tableDiv" style="height:auto;margin-top:10px;">
	<div class="tableDiv" >
            <div class="rowTableDiv" > 
                <div class="cellTableDiv widthContent divFloat darkBlueEffect leftTopRadiusDiv rightTopRadiusDiv"  style="height: 25px;"> 
                    <table class="widthTableHead textColorWhite tableGridNew textAlignLeft" style="">
                            <thead >
                                    <tr>
							<td width="5%">Id</td>
							<td width="20%">Nominativo</td>
                                          <td width="20%">Campagna</td>
							<td width="15%">Data Ricontattare</td>
							<td width="40%">Note</td>
                                    </tr>
                            </thead>
                    </table>
                </div>
            </div>	
	</div>
                
	<div class="rowTableDiv" >
		<div class="widthMax100 divFloat lightGreyDiv3 scrollContent2"> 
			
			<table class="widthMax100 tableGridNew textAlignLeft">	
				<tbody>
					{section name=idx loop=$nominativoLS}
					<tr class="{cycle values='rowDispariNew,rowPariNew'}" id="tr_{$idListaLS[idx]}" 
						onClick = "modApp({$idListaLS[idx]},'{$operatorePerRicontattareLS[idx]}','{$telefonoPerRicontattareLS[idx]}')">
						<td width="5%">{$idListaLS[idx]}</td>
						<td width="20%">{$nominativoLS[idx]}</td>
						<td width="20%">{$campagnaLS[idx]}</td>
						<td width="15%">{$dataRicontattareLS[idx]}</td>
						<td width="40%">{$noteLS[idx]}</td>
					</tr>
					{sectionelse}
						<tr >
							<td class="rowNoElements" style="font-size:14px;height:254px;">Nessun elemento trovato</td>
						</tr>	
					{/section}
				</tbody>
			</table>
		</div>
	</div>


        <div class="tableDiv" >
		<div class="rowTableDiv" >                        
			<div class="cellTableDiv widthContent divFloat darkBlueEffect leftBottomRadiusDiv rightBottomRadiusDiv"  style="height: 0px;"> 
				&nbsp;
			</div>
		</div>			
	</div>	

</div>



<div id="hiddenDivApp" class="divPopupObject" style="display: none;height	: 100%;">	
	<div class="divPopupObjectBox shadowDiv radiusTable " style="background-color:#CECECE;position:fixed;">
		<div class="shadowTextGrey" style="text-align:center;height:20px; margin-top:30px;font-size:14px;"> 
			<b>Prendi un'appuntamento</b>
		</div>
		<div style="text-align:center; margin-top:10px; "> 
			<input type="text" name="dataAppuntamento" id="dataAppuntamento" value="{$dataAppuntamento}" class="inputGeneral1 radiusInput width150" readOnly/>
					<input type="button" class="buttonCanc" onclick="CalendarClear('dataAppuntamento','','')" value="" title="Cancella Data" />&nbsp;&nbsp;
					<input type="button" class="buttonCalendar2" onclick="popupCalendar('dataAppuntamento',event,'{$maxDate}','','{$todayDate}')" />
					&nbsp;&nbsp;&nbsp;&nbsp;
					<select name="oraAppuntamento" id="oraAppuntamento" class="selectGeneric2 radiusInput" onChange="">
						<option value="" selected>...</option>
						<option value="08:00">08:00</option><option value="08:15">08:15</option><option value="08:30">08:30</option><option value="08:45">08:45</option>
						<option value="09:00">09:00</option><option value="09:15">09:15</option><option value="09:30">09:30</option><option value="09:45">09:45</option>
						<option value="10:00">10:00</option><option value="10:15">10:15</option><option value="10:30">10:30</option><option value="10:45">10:45</option>
						<option value="11:00">11:00</option><option value="11:15">11:15</option><option value="11:30">11:30</option><option value="11:45">11:45</option>
						<option value="12:00">12:00</option><option value="12:15">12:15</option><option value="12:30">12:30</option><option value="12:45">12:45</option>
						<option value="13:00">13:00</option><option value="13:15">13:15</option><option value="13:30">13:30</option><option value="13:45">13:45</option>
						<option value="14:00">14:00</option><option value="14:15">14:15</option><option value="14:30">14:30</option><option value="14:45">14:45</option>
						<option value="15:00">15:00</option><option value="15:15">15:15</option><option value="15:30">15:30</option><option value="15:45">15:45</option>
						<option value="16:00">16:00</option><option value="16:15">16:15</option><option value="16:30">16:30</option><option value="16:45">16:45</option>
						<option value="17:00">17:00</option><option value="17:15">17:15</option><option value="17:30">17:30</option><option value="17:45">17:45</option>
						<option value="18:00">18:00</option><option value="18:15">18:15</option><option value="18:30">18:30</option><option value="18:45">18:45</option>
						<option value="19:00">19:00</option><option value="19:15">19:15</option><option value="19:30">19:30</option><option value="19:45">19:45</option>
						<option value="20:00">20:00</option><option value="20:15">20:15</option><option value="20:30">20:30</option><option value="20:45">20:45</option>
					</select>	
					&nbsp;&nbsp;&nbsp;&nbsp;
					<select name="operatoreApp" id="operatoreApp" class="selectGeneric2 radiusInput">
						<option value="">...</option>
						{section name=idx loop=$operatoreLS}
							<option value="{$operatoreLS[idx]}">{$operatoreLS[idx]} {$nominativoOperatoreLS[idx]}</option>
						{/section}
					</select>
		</div>
		<div style="margin-top:20px;">
			
			<b>Telefono da richiamare</b>&nbsp;&nbsp;&nbsp;&nbsp;
	
			<input type="text" name="telefonoApp" id="telefonoApp" value="" class="inputGeneral1 radiusInput width150"/>
		</div>
		<div style="margin-top:20px;"> 
			<input type="button" class="buttonNew3 radiusButton shadowButton effectImage " onclick="_checkEsito()" value="Fine" />&nbsp;&nbsp;
			<input type="button" class="buttonNew3 radiusButton shadowButton effectImage " onClick="modApp(0)" value="Annulla" />	
		</div>
	</div>
</div>
<!--<div class="widthContent textAlignRight tableDiv" style="margin-top:20px;" >
	<input type="button" id="idButtonProssimo" value="Prossimo Cliente" class="buttonNew3 effectImage radiusButton shadowButton" style="visibility:hidden;" onclick="_prossimoCliente()"/>
</div>-->


<input type="hidden" name="order" id="order" value="{$order}" />
<input type="hidden" name="orderType" id="orderType" value="{$orderType}" />


<input type="hidden" name="idListaApp" id="idListaApp" value="" />
<input type="hidden" name="idEsito" id="idEsito" value="" />
<input type="hidden" name="save" id="save" value="" />


</br>


{include file="funcMisc.js"}
{include file="funcSelect.js"}
{include file="funcPopup.js"}
{include file="usrObjPopupMsg.tpl.html"}

<input type="hidden" name="nextCli" id="nextCli" value="" />

<script type="text/javascript" src="lib_js/calendar.js"></script>
<script type="text/javascript">


// alert ('{$idCampagna}');

// loginConsole2(loginCheck);

{literal}

	function _checkEsito()
	{
		popMsg.resetValueObjMsg();
				
		if (document.main.dataAppuntamento.value == '')
		{
		    //usrMessageDsc = "Inserire la data dell'appuntamento";
		    //popMsg.warning();	
			alert ("Inserire la data dell'appuntamento");
			return;
		}

		if (document.main.oraAppuntamento.value == '')
		{
// 				    usrMessageDsc = "Inserire l'ora dell'appuntamento";
// 				    popMsg.warning();	
			alert ("Inserire l'ora dell'appuntamento");
			return;
		}
		
		if (document.main.telefonoApp.value == '')
		{
// 				    usrMessageDsc = "Inserire l'ora dell'appuntamento";
// 				    popMsg.warning();	
			alert ("Inserire il telefono da richiamate");
			return;
		}	

		if (document.main.operatoreApp.value == '')
		{
// 				    usrMessageDsc = "Inserire l'ora dell'appuntamento";
// 				    popMsg.warning();	
			alert ("Inserire l'operatore per richiamare");
			return;
		}	

		document.main.save.value = "S";
		document.main.idEsito.value = 20;
				
		document.main.submit();
// 		var par = "&save=S&idEsito=20&operatoreApp="+document.main.operatoreApp.value;
// 		par += "&dataAppuntamento="+document.main.dataAppuntamento.value+"&oraAppuntamento="+document.main.oraAppuntamento.value;
// 		par += "&telefonoApp="+document.main.telefonoApp.value;
// 		par += "&noteOperatore="+document.main.noteOperatore.value;

				//_submitLoadScript(par)
	}			
		
	function modApp(idlista,operatore,telefono) 
	{
		return;
		document.main.idListaApp.value = idlista;
		document.main.telefonoApp.value = telefono;
		selectOption("operatoreApp",operatore);

		if ($("#hiddenDivApp").is(":hidden")) 
		{
			$("#hiddenDivApp").fadeIn("slow");	
		} 
		else 
		{
			$("#hiddenDivApp").fadeOut("slow");
		}
	}

{/literal}


</script>
 

{include file="footerPopup.tpl.html"} 
 

